function y = ltrmat(x)
% LTRMAT(X)
%   creates a symmetric matrix from vectorization of a lower triangular matrix

% June 9, 2004
% Sungbae An

n = sqrt(size(x,1)*2 + 1/4) - 1/2;
y = zeros(n,n);
y(find(tril(ones(n,n)))) = x;

y = symmat(y);
